package com.toy.abash.domain;

import java.util.Date;

import org.springframework.data.annotation.Id;
import org.springframework.data.mongodb.core.index.Indexed;
import org.springframework.data.mongodb.core.mapping.Document;

import com.toy.core.domain.BaseObject;

/**
 * 糗事回帖
 */
@Document(collection="T_REPLIES")
public class Reply implements BaseObject {
	
	private static final long serialVersionUID = 7254582589802974481L;
	
	public static int STATE_NORMAL = 0;
	public static int STATE_HIDDEN = 1;
	
	@Id
	private long id;
	@Indexed
	private long abashId; //关联的糗事
	@Indexed
	private long replierId; //回复人
	private Date replyDate; //回复时间
	private String content; //回复内容
	private String ipaddress; //ip地址
	@Indexed
	private int state; //状态
	private boolean anonymousPost; //匿名提交
	
	public long getId() {
		return id;
	}

	public void setId(long id) {
		this.id = id;
	}

	public Date getReplyDate() {
		return replyDate;
	}

	public void setReplyDate(Date replyDate) {
		this.replyDate = replyDate;
	}

	public String getContent() {
		return content;
	}

	public void setContent(String content) {
		this.content = content;
	}

	public String getIpaddress() {
		return ipaddress;
	}

	public void setIpaddress(String ipaddress) {
		this.ipaddress = ipaddress;
	}

	public int getState() {
		return state;
	}

	public void setState(int state) {
		this.state = state;
	}

	public boolean isAnonymousPost() {
		return anonymousPost;
	}

	public void setAnonymousPost(boolean anonymousPost) {
		this.anonymousPost = anonymousPost;
	}

	public long getAbashId() {
		return abashId;
	}

	public void setAbashId(long abashId) {
		this.abashId = abashId;
	}

	public long getReplierId() {
		return replierId;
	}

	public void setReplierId(long replierId) {
		this.replierId = replierId;
	}
	
}
